
if(NOT TARGET google-test)
  cpmaddpackage(
    NAME google-test #
    VERSION 1.14.0 #
    # URL "https://github.com/google/googletest/archive/refs/tags/v1.17.0.zip" #
    URL "https://gitee.com/mirrors/googletest/repository/archive/main.zip"
  )
  # 强制使用动态链接库
  set(gtest_force_shared_crt
    ON
    CACHE BOOL "" FORCE)
endif()
